<template>
	<view>
		<view class="container" style="font-size: 28px;">

			<uni-nav-bar shadow left-icon="left" @clickLeft="back" leftText="返回" rightText="我的会议" title="会议室列表"
				@clickRight="right()" />
		</view>

		<view style="clear:both" v-for="(item, index) in socialList" :key="item.cid" :ref="'item'+index"
			@click="onclick(item)">
			<uni-card :title="item.conferencename">

				<view
					style="background-color: #6c76f4; width: 50px;border-radius:5px;float: left;margin: -45px 0px 30px 120px;">
					<text style="color: #fff;margin-left: 10px;">{{item.conferencetype == 1?"空闲":"使用" }}</text>
				</view>

				<view style="clear:both">

					<text class="uni-body text1">会议室地址：</text>
					<text class="uni-body text2">{{item.address}}</text>

				</view>
				<view>
					<text class="uni-body text1">公积金：</text>
					<text class="uni-body text2">{{item.address}}</text>
				</view>

			</uni-card>
		</view>
	</view>
</template>


<script >
	export default {
		data() {
			return {
				socialList: []
			}
		},
		created() {
			uni.request({
				url: "http://localhost:8007/conference/conference/findAll",
				method: 'get',
				success: (res) => {
					console.log(res)
					this.socialList = res.data.data.list
					// console.log(this.dataList[0].paytime.)
				}
			})
		},
		methods: {
			back() {
				uni.switchTab({
					url: "../../index/index",
				})
			},
			right() {
				uni.navigateTo({
					url: "./my",
				})
				console.log("111111111");
			},
			onclick(e) {
				uni.navigateTo({
					url: "./details?cid=" + e.cid,
				})
			},
		}
	}
</script>


<style>

</style>
